package com.h3c.nem.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.h3c.nem.dto.TbPreWorkerDTO;
import com.h3c.nem.dto.TbPreWorkerSeaDTO;
import com.h3c.nem.entity.SdDept;
import com.h3c.nem.entity.TbPreWorker;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;

import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * Copyright (C), 2020-2020, h3c
 * FileName: TbPreWorkerMapper
 *
 * @Author: l22886
 * @Date: 2022-01-19
 * Description: tb_pre_worker mapper
 * Version: 1.0
 */
public interface TbPreWorkerMapper extends BaseMapper<TbPreWorker> {

    /**
     * @title: queryListByFuzzy
     * @description: 模糊列表查询
     * @params: [ TbPreWorker ]
     * @return: java.util.List
     * @createTime: 2022-01-19
     * @version: 1.0
     * @author: l22886
     */
    public List<TbPreWorker> queryListByFuzzy(TbPreWorker TbPreWorker);

    /**
     * @title: queryListByFuzzy
     * @description: 精确列表查询
     * @params: [ TbPreWorker ]
     * @return: java.util.List
     * @createTime: 2022-01-19
     * @version: 1.0
     * @author: l22886
     */
    public List<TbPreWorkerDTO> queryList(TbPreWorkerSeaDTO TbPreWorker);

    /**
     * @title: updateTbPreWorker
     * @description: 更新
     * @params: [ TbPreWorker ]
     * @return: java.lang.Integer
     * @createTime: 2022-01-19
     * @version: 1.0
     * @author: l22886
     */
    public Integer updateTbPreWorker(TbPreWorker TbPreWorker);

    /**
     * @title: insertTbPreWorker
     * @description: 插入
     * @params: [ TbPreWorker ]
     * @return: java.lang.Integer
     * @createTime: 2022-01-19
     * @version: 1.0
     * @author: l22886
     */
    public Integer insertTbPreWorker(TbPreWorker TbPreWorker);

    /**
     * @title: deleteTbPreWorker
     * @description: 删除
     * @params: [ TbPreWorker ]
     * @return: java.lang.Integer
     * @createTime: 2022-01-19
     * @version: 1.0
     * @author: l22886
     */
    public Integer deleteTbPreWorker(TbPreWorker TbPreWorker);

    List<Map<String, Object>> countPreGroupByDay(@Param("startTime") Date startTime,
                                           @Param("endTime") Date endTime,
                                           @Param("deptId") Set<Integer> deptId);
}
